//
//  HtmlCollector.h
//  MarketDataColloctor
//
//  Created by jiro on 10/03/04.
//  Copyright 2010 jiro music. All rights reserved.
//

#import <Cocoa/Cocoa.h>

@interface WebResourceCollector : NSObject {

	BOOL yahooEnigmaOption;

	NSStringEncoding htmlEncoding;
	
	int threadCount;

	NSMutableArray* errorInfos;	//	key: url and save path value: error message
}

- (id) init;

- (id) initWithYahooEnigmaOption: (BOOL) enable htmlEncoding: (NSStringEncoding) encoding;

- (id) initWithEncoding: (NSStringEncoding) encoding;

// save contents as utf8 text
// urls is correspond to paths
//- (void) collectContentsOf: (NSDictionary*) urlAndSavePaths;
- (void) collectContentsOf: (NSArray*) urls intoStrings: (NSMutableArray*) htmlStrings;

- (NSString*) collectContentsOf: (NSURL*) url;

- (NSString*) errorMessage;

-(NSString*) outputUrls: (NSArray*) codes andMarketDataType: (int) marketDataType;

@end
